import java.util.Scanner;

public class fish {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int []arr=new int[n];
        int []arr2=new int[n];
        for (int i = 0; i < n; i++) {
            arr[i]=sc.nextInt();
        }
        for (int i = 0; i < n; i++) {
            int cnt=0;
            for (int j = 0; j< i; j++){
                if(arr[j]<arr[i])cnt++;
            }
//            arr2[i]=cnt;
            System.out.print(cnt+" ");
        }
//        for (int i = 0; i < n; i++) {
//            System.out.print(arr2[i]+" ");
//        }
    }
}
